package leetcode_501_600;

public class LeeCode_507 {
    public static void main(String[] args) {

    }
    private static boolean checkPerfectNumber(int num) {
        if (num == 1)
            return false;
        int i = 2, sum = 1;
        while (i * i <= num){
            if (num % i == 0){
                sum += num / i + i;
            }
            i++;
        }
        return sum == num;
    }
}
